package game.vo
{
	import flash.events.EventDispatcher;
	
	import game.events.SceneEvent;
	import game.model.SceneModel;
	import game.view.scene.MapAssetBase;

	public class SceneVO extends EventDispatcher
	{
		private var _mapConfig:XML;
		private var _mapName:String;
		private var _mapDescription:String;
		private var _mapRow:int=0;
		private var _mapCols:int=0;
		private var _cellSize:Number;
		private var _roadArray:Array=[];
		private var _assetLibPath:Array=[];
		private var _assetArray:Vector.<MapAssetBase>=new Vector.<MapAssetBase>();
		private var _mapType:int=0;//地图类型:0=Diamond;1=Staggered
		
		public function SceneVO()
		{
		}
		
		public function get mapName():String
		{
			return _mapName;
		}
		
		public function set mapName(value:String):void
		{
			_mapName = value;
		}
		
		public function get mapDescription():String
		{
			return _mapDescription;
		}
		
		public function set mapDescription(value:String):void
		{
			_mapDescription = value;
		}
		
		/**
		 *地图上所有物件列表
		 */		
		public function get assetArray():Vector.<MapAssetBase>
		{
			return _assetArray;
		}
		
		/**
		 *地图上所有物件列表
		 */	
		public function set assetArray(value:Vector.<MapAssetBase>):void
		{
			_assetArray = value;
		}
		
		public function get mapRow():int
		{
			return _mapRow;
		}
		
		public function set mapRow(value:int):void
		{
			_mapRow = value;
		}
		
		public function get mapCols():int
		{
			return _mapCols;
		}
		
		public function set mapCols(value:int):void
		{
			_mapCols = value;
		}
		
		public function get cellSize():Number
		{
			return _cellSize;
		}
		
		public function set cellSize(value:Number):void
		{
			_cellSize = value;
		}
		
		public function get roadArray():Array
		{
			return _roadArray;
		}
		
		public function set roadArray(value:Array):void
		{
			_roadArray = value;
		}
		
		/**
		 *地图资源库Xml配置路径
		 */		
		public function get assetLibPath():Array
		{
			return _assetLibPath;
		}
		
		/**
		 *地图资源库Xml配置路径
		 */
		public function set assetLibPath(value:Array):void
		{
			_assetLibPath = value;
		}
		
		/**
		 *地图类型:0=Diamond;1=Staggered 
		 */		
		public function get mapType():int
		{
			return _mapType;
		}
		
		/**
		 *地图类型:0=Diamond;1=Staggered 
		 */		
		public function set mapType(value:int):void
		{
			_mapType = value;
		}

		public function get mapConfig():XML
		{
			return _mapConfig;
		}

		public function set mapConfig(value:XML):void
		{
			_mapConfig = value;
			dispatchEvent(new SceneEvent(SceneEvent.MAP_CONFIG_CHANGE));
		}
	}
}